import { createRouter, createWebHistory } from 'vue-router'
import HomeView from '../views/Home/index.vue'

const router = createRouter({
  history: createWebHistory(import.meta.env.BASE_URL),
  routes: [
    {
      path: '/',
      redirect: '/home',
    },
    {
      path: '/home',
      name: 'home',
      component: HomeView,
    },
    {
      path: '/user',
      name: 'user',
      component: ()=> import("@/views/User/index.vue"),
    },
    {
      path: '/login',
      name: 'login',
      component: ()=> import("@/views/Login/index.vue"),
    },
  ],
})

export default router
